<form name="absoluteTime" ng-submit="applyAbsolute()">
  <div class="kbn-timepicker-body">
    <div class="kbn-timepicker-section kbn-timepicker-body-column">
      <div class="kuiLocalDropdownHeader kbn-timepicker-form-header">
        <label class="kuiLocalDropdownHeader__label">
          From
        </label>

        <div class="kuiLocalDropdownHeader__actions">
          <a
            class="kuiLocalDropdownHeader__action"
            ng-click="setToNow({key:'from'})"
            kbn-accessible-click
          >
            Set To Now
          </a>
        </div>
      </div>

      <input
        type="text"
        required
        class="kuiTextInput fullWidth"
        input-datetime="{{format}}"
        ng-model="absolute.from"
      >
      <div ng-show="!absolute.from"><em>Invalid Date</em></div>

      <div>
        <datepicker ng-model="pickFromDate" ng-model-options="{ getterSetter: true }" max-date="absolute.to" show-weeks="false"></datepicker>
      </div>
    </div>

    <div class="kbn-timepicker-section kbn-timepicker-body-column">
      <div class="kuiLocalDropdownHeader kbn-timepicker-form-header">
        <label class="kuiLocalDropdownHeader__label">
          To
        </label>

        <div class="kuiLocalDropdownHeader__actions">
          <a
            class="kuiLocalDropdownHeader__action"
            ng-click="setToNow({key:'to'})"
            kbn-accessible-click
          >
            Set To Now
          </a>
        </div>
      </div>

      <span ng-show="!absolute.to"><em>Invalid Date</em></span>
      <input
        type="text"
        required
        class="kuiTextInput fullWidth"
        input-datetime="{{format}}"
        ng-model="absolute.to"
      >

      <div>
        <datepicker ng-model="pickToDate" ng-model-options="{ getterSetter: true }" min-date="absolute.from" show-weeks="false"></datepicker>
      </div>
    </div>
  </div>

  <div class="kbn-timepicker-actions kuiVerticalRhythm">
    <span
      class="kbn-timepicker-action-item kbn-timepicker-error"
      ng-show="absolute.from > absolute.to"
    >
      <strong>From</strong> must occur before <strong>To</strong>
    </span>
    <button
      type="submit"
      class="kuiButton kuiButton--primary kbn-timepicker-submit-button"
      ng-disabled="absolute.from > absolute.to || !absolute.from || !absolute.to"
      data-test-subj="timepickerGoButton"
    >
      Go
    </button>
  </div>
</form>
